#ifndef BARRIER_H
#define BARRIER_H

#include <QObject>
#include <QGraphicsPixmapItem>
#include<QPropertyAnimation>


class barrier : public QObject,public QGraphicsPixmapItem
{
    Q_OBJECT
    Q_PROPERTY(QPointF pos READ getPos WRITE setPos1)
public:
    explicit barrier(const QPixmap& pixmap,qreal barrier_x,qreal barrier_y,QObject *parent = nullptr);
    QPropertyAnimation* barriermove;
    QPointF getPos() const
    {
        return m_pos;
    }
    void setPos1(const QPointF &pos);

signals:
private:
    QPointF m_pos;
};

#endif // BARRIER_H
